import pymysql
import json
insert_sql = '''select return_json from unit_chat'''
db = pymysql.connect(host='127.0.0.1',
                         port=3306,
                         user='root',
                         password='123456',
                         database='unit',
                         charset='utf8')
cursor = db.cursor()

cursor.execute(insert_sql)
data = cursor.fetchall()
db.commit()
print(data[1][0])
print(type(data[1][0]))
db.rollback()
db.close()